// dlg.txt

begintalkscript;

variables;

begintalknode 1;
	state = -1;
	nextstate = -1;
	condition = get_sdf(33,2) == 0;
	question = "special";
	text1 = "You continue your journey through the Okavano swamp. This seemingly endless fen only grows wetter and more difficult as you pass east. This road provides one of the few easy routes through this area. Certainly the only path an army could easily use.";
	text2 = "That bit of knowledge is not lost on the rebels. Through the mist, you can dimly make out a large, stone barrier. Many creations and other defenders are camped in front of it.";
	text3 = "To the north, you can see one of the few solid features in the swamp. It is a sharp, jagged spire of rock, protruding from the mire. You think that you can see a flickering light at the top of it.";
	action = SET_SDF 33 2 1;

begintalknode 2;
	state = -1;
	nextstate = -1;
	condition = get_sdf(33,4) == 0;
	question = "special";
	text1 = "Now that you are closer, you can see more details about the barrier. It not only has dozens of defenders, but you can make out the huge, glowing forms of several Unbound. They are chained to the wall.";
	text2 = "Right now, they appear to be passive. They have not yet received the command that removes all restraints from them and turns them into relentless killing machines.";
	text3 = "Of course, as you approach the camp, their guards see you. They don't appear to want to attack you. Yet. Instead, one scout leaves the camp and walks nervously toward you.";
	action = SET_SDF 33 4 1;

begintalknode 3;
	state = -1;
	nextstate = -1;
	condition = get_sdf(33,3) == 0;
	question = "special";
	text1 = "This raised, dry area contains something very unusual. It is a building, of recent construction. It's not a ruin. The rebels built it. It has massive stone walls, several feet thick.";
	text2 = "The swamp has come close to it, but it has not, so far, begun to sink into the mud.";
	text3 = "When you get close to it, your skin tingles. Your hair stands slightly on end. No sign identifies this building, but something powerful must be inside. Your curiosity is piqued.";
	action = SET_SDF 33 3 1;

begintalknode 4;
	state = -1;
	nextstate = -1;
	condition = get_sdf(33,5) == 0;
	question = "special";
	text1 = "There is a large camp of creations to the south. Huge, lumbering humanoids. They gnaw on bones and snarl at each other. And, when you get close, one of them sees you. It growls and throws a handful of dung in your direction. Inaccurately, fortunately.";
	text2 = "They are big, they aren't friendly, and they feel that the bit of miserable swamp to the south is their territory.";
	text3 = "For a moment, you feel a powerful wave of rage. Something about the insolence of this mere creation is infuriating. You manage, with effort, to calm down. You refuse to let your occasional moods drag you into suicide.";
	action = SET_SDF 33 5 1;

begintalknode 5;
	state = -1;
	nextstate = -1;
	condition = get_sdf(33,6) == 0;
	question = "special";
	text1 = "A narrow strip of dry land leads to the base of the northern rock spire. Though some effort has been made to conceal them, you can barely make out tracks in the wet earth.";
	text2 = "Someone is definitely hiding to the north, and at least a few people have traveled in and out recently.";
	action = SET_SDF 33 6 1;


begintalknode 6;
	state = -1;
	nextstate = -1;
	condition = gf(33,13) == 0 && gf(33,14) == 0;
	question = "special";
	text1 = "As you circle the strange bunker, you see no signs or symbols that would identify what is inside. There is only one door. It is as solidly built and impenetrable as the rest of the structure.";
	text2 = "The only features in the surface of the door are two depressions, each about the size of a walnut. You don't have anything that would fit inside them.";
	text3 = "The only features in the surface of the door are two depressions, each about the size of a walnut. They look similar to the odd, glowing gemstone you have in your pack. You put it in the hole, and it is a perfect fit.";
	text4 = "However, putting a crystal in only one of the holes does nothing. You retrieve the gem and put it back in your pack.";
	text5 = "The only features in the surface of the door are two depressions, each about the size of a walnut. They look similar to the odd, glowing gemstones you have in your pack. You put them in the holes. They fit perfectly.";
	text6 = "You try to retrieve the stones, but they refuse to come out of the holes. There must be a way to get the stones to fall out, maybe a command word, but you don't know it. You hear a deep clunking sound, coming from inside the door. ";
	code =
		sf(33,14,1);
		clear_strings();
		as(1);
		if (num_of_item(462) == 0)
			as(2);
			else if (num_of_item(462) == 1) {
				as(3); as(4);
				}
				else {
					as(5); as(6);
					take_item(462);
					take_item(462);
					sf(33,13,1);
					}
	break;
	
begintalknode 7;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "The sign says:";
	text2 = "  Okavano Road";
	text3 = "  Mera-Tev - West";
	text4 = "  Burwood Province - East";

begintalknode 8;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "The sign says:";
	text2 = "  DIVIDING LINE";
	text3 = "  Travelers crossing without permission will be destroyed.";
	
begintalknode 10;
	state = -1;
	nextstate = 10;
	condition = 1;
	question = "Name";
	text1 = "One of the rebels slowly approaches you. He has a baton in his hand, but he isn't pointing it at you. He seems to feel, correctly, that if you decide to kill him the baton won't be much of a help.";
	text2 = "He says, _I am Preya. I mean you no harm. I've been sent to warn you away from the barrier. We don't want to kill you unless we have to. Just stay away from our camp, and we won't have to fight._";
	text5 = "Preya says, _What else do you need, traveler?_ He has relaxed slightly. If you wanted to kill him, he has decided, you would have gotten on with it by now.";
	action = INTRO;

begintalknode 11;
	state = 10;
	nextstate = 11;
	condition = 1;
	question = "Tell me about this part of the fen.";
	text1 = "He looks suspicious, and rightly so. _We aren't hunting for spies, but that doesn't mean that we welcome them, either._";
	text2 = "With a little quick diplomacy, you manage to convince him that you aren't a spy, just a cautious traveler. _I can tell you a little bit. Just nothing about our defenses._";
	code =
		if (get_stat(20) < 4)
			rs(2);
	break;
	
begintalknode 12;
	state = 11;
	nextstate = 12;
	condition = get_stat(20) >= 4;
	question = "Tell me about the stone spire to the north.";
	text1 = "_We don't go there. We've been told to stay away. Some people are hiding back there. Eccentrics. Our orders are to just leave them alone._";

begintalknode 13;
	state = 11;
	nextstate = -1;
	condition = get_stat(20) >= 4;
	question = "What is to the south?";
	text1 = "He looks nervous. _Just some creations. Pretty savage. We're waiting for a Lifecrafter to come and calm them down._";
	text2 = "_You should just stay away from there._";

begintalknode 14;
	state = 12;
	nextstate = -1;
	condition = 1;
	question = "Eccentrics?";
	text1 = "_That's all I know. I've heard rumors, but nothing I believe enough to pass on. They hide back there. Sometimes, when it's dark, they slip in and out._";
	text2 = "_All I know is that, as long as they only go west and don't try to enter our lands, I'm to leave them alone. I guess, that way, they bother the Shapers more than us._";

begintalknode 15;
	state = 10;
	nextstate = 13;
	condition = 1;
	question = "Can I pass the barrier?";
	text1 = "_You're not a rebel. You're not one of us. If you pass the dividing line, we'll have to kill you. No offense._";

begintalknode 16;
	state = 13;
	nextstate = -1;
	condition = 1;
	question = "What is the dividing line?";
	text1 = "_If you go east and see a line of stone posts, don't cross it. That's how we've been told to mark our territory. On this side, we have no problem with you. Set one foot over ..._ He waves his baton and makes a _Thwip thwip!_ sound.";

begintalknode 17;
	state = 13;
	nextstate = -1;
	condition = 1;
	question = "Why are you all staying at the barrier?";
	text1 = "_Don't ask me. We get orders. We follow them. The rumors are that our generals are negotiating with the Shapers, and we don't want to aggravate the other side while that's going on._";
	text2 = "_All right by me. I'd rather sit in the swamp than fight. We have spores to treat us if we get sick, but there's no pod to cure getting your head blasted off._";

begintalknode 18;
	state = 13;
	nextstate = -1;
	condition = 1;
	question = "Tell me about those Unbound.";
	text1 = "He shudders. _We watch them. We feed them. We don't let them loose into the Mera-Tev. Yet. But I hate having them around._";

begintalknode 19;
	state = 10;
	nextstate = -1;
	condition = 1;
	question = "You're a human, not a creation?";
	text1 = "_There are plenty of humans in the rebellion. People who got sick of the Shapers hoarding all the magic and all the power. And we'll keep fighting alongside the serviles, as long as the drakons don't get too arrogant._";
	
begintalknode 20;
	state = 10;
	nextstate = -1;
	condition = 1;
	question = "Prepare to die, rebel. (Attack.)";
	text1 = "_Oh, no._";
	text2 = "Preya raises his baton. When the rebels see what is happening, they get ready to help their scout.";
	action = END_TALK;
	code =
		sf(33,8,1);

	break;
	
begintalknode 21;
	state = 10;
	nextstate = -1;
	condition = 1;
	question = "Thank you for the information.";
	text1 = "Preya nods. _Glad to help. Just stay back from the dividing line, and you should be fine._ He turns and marches back to his camp.";
	action = END_TALK;

	
begintalknode 26;
	state = -1;
	nextstate = -1;
	condition = gf(33,7) == 0;
	question = "special";
	text1 = "From this angle, you can see a thin strip of solid land to the south. To the south, it is obscured by marsh reeds. Whoever is hiding back here, they must use this route to quickly slip in and out.";	
	code =
		sf(33,7,1);
		set_floor(13,13,0);
		set_floor(13,14,0);
		set_floor(13,15,0);
		set_floor(13,16,0);
		set_floor(14,13,0);
		set_floor(14,14,0);
		set_floor(14,15,0);
		set_floor(14,16,0);
	break;
	
begintalknode 27;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "You step between the stone posts. The effect is immediate.";
	text2 = "The rebels shout, _Repel the attacker! Get the Shaper spy!_ They jump to their feet and grab their weapons. Then they slowly and carefully advance upon you.";
	text3 = "You see one servile go back to the Unbound, ready to release them if necessary.";

begintalknode 28;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "A furious screech echoes across the swamp. You look at the barrier and see a huge, glowing monstrosity break loose from its chains.";
	text2 = "You have killed enough of the rebels to infuriate the Unbound. They are breaking free from their bonds.";

begintalknode 29;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "";	
	
	//

begintalknode 30;
	state = -1;
	nextstate = 30;
	condition = 1;
	question = "Name";
	text1 = "Once again, you have tracked down the intelligent ornk. It no longer attempts to disguise the telltale white spot on its side. Instead, it stands in the middle of this field of fungus and boldly stares you down.";
	text2 = "It begins to speak, carefully and painfully extracting words from a throat and lungs not designed to provide them. It says, _Nooo goooo. Leave me aloooone. Noooo die._";

begintalknode 31;
	state = 30;
	nextstate = -1;
	condition = get_stat(20) < 7;
	question = "The Shapers won't kill you. They just want to study you. (Lie.)";
	text1 = "The ornk isn't very smart, but it wasn't born yesterday. It knows how humans treat its kind.";
	text2 = "_Nooooo. Noooo gooo. Nooo die._";

begintalknode 32;
	state = 30;
	nextstate = 31;
	condition = get_stat(20) >= 7;
	question = "The Shapers won't kill you. They just want to study you. (Lie.)";
	text1 = "The ornk is remarkably smart for its kind, but it's no bovine super-genius. It believes your lie. _Nooooo? Noooo kill? I goooo back, and I live?_";

begintalknode 33;
	state = 31;
	nextstate = -1;
	condition = 1;
	question = "They would never kill, dissect, and study a magnificent creature like you. You should go back.";
	text1 = "The ornk believes your honeyed words of treachery. _I goooo. I goooo back. I will teach them about my kind. Bring a new peace between two-legs and ornk. Thank yooou. Thank yooooooou._";
	text2 = "The ingenious, painfully naive creature begins its long march back to the Mera-Tev.";
	action = END_TALK;
	code =
		sf(33,1,2);
		sf(33,18,1);
		award_party_xp(100,15);
	break;
	
begintalknode 34;
	state = 31;
	nextstate = 30;
	condition = 1;
	question = "I can't lie to you. You're right. They'll kill you.";
	text1 = "The ornk looks dejected. _Nooooo. Want toooo live. Noooo die._";

begintalknode 35;
	state = 30;
	nextstate = -1;
	condition = 1;
	question = "You are a rogue. By the laws of the Shapers, you have to die.";
	text1 = "_Noooo! Noooo die! I have friends. Other rooooogues. They help._ It lets out a long moo of alarm. _Noooo gooo! Noooo goooo!_";
	action = END_TALK;
	code =
		inc_flag(100,0,3);
		set_attitude(34,10);
		activate_hidden_group(1);
		set_attitude(1004,10);
	break;
	
begintalknode 36;
	state = 30;
	nextstate = -1;
	condition = 1;
	question = "I will spare you. You should run before the Shapers get you.";
	text1 = "The ornk is surprised and touched that you would ignore the laws of the Shapers on its behalf. A single tear runs down its pink, fuzzy face. _Yoooou help me? There is hooooope for ornk and two-legs after all. Thank yooou. Thank yooooooou._";
	text2 = "It runs away. You can always just tell Flesch that you killed it.";
	action = END_TALK;
	code =
		inc_flag(100,0,-3);
		sf(33,18,1);
		sf(33,1,1);
	break;

begintalknode 37;
	state = 30;
	nextstate = -1;
	condition = 1;
	question = "I don't know what to do about you. Just wait here.";
	text1 = "_Noooo. Noooo go. Yoooou knooooow where I am. Yooooou get me dead. Bad two-legs! I have friends. Other rooooogues. They help._ It lets out a long moo of alarm.";
	action = END_TALK;
	code =
		set_attitude(34,10);
		activate_hidden_group(1);
		set_attitude(1004,10);
	break;

begintalknode 40;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = "The noble, intelligent ornk expires. Another wonder has been denied to the world.";
	
//

begintalknode 50;
	state = -1;
	nextstate = 50;
	condition = 1;
	question = "Name";
	text1 = ".";
	text2 = "";
	text5 = ".";
	action = INTRO;

begintalknode 51;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

	
begintalknode 52;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
	
begintalknode 53;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
	
begintalknode 54;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
	
begintalknode 55;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
	
begintalknode 56;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
	
begintalknode 57;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
	
begintalknode 58;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

begintalknode 59;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

begintalknode 60;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

begintalknode 61;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

begintalknode 62;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

begintalknode 63;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

begintalknode 64;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

//

begintalknode 70;
	state = -1;
	nextstate = 70;
	condition = 1;
	question = "Name";
	text1 = ".";
	text2 = "";
	text5 = ".";
	action = INTRO;

begintalknode 71;
	state = 70;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

//

begintalknode 90;
	state = -1;
	nextstate = 90;
	condition = 1;
	question = "Name";
	text1 = ".";
	text2 = "";
	text5 = ".";
	action = INTRO;

begintalknode 91;
	state = 90;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
		